package springboot.file.demo.pojo.vo;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDate;
import java.util.List;

/**
 * @Author: jxm
 * @Description:
 * @Date: 2021/8/5 14:33
 * @Version: 1.0
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
@ApiModel(value="Excel导出对象", description="Excel导出对象")
public class ExcelDto implements Serializable {

    @ApiModelProperty(value = "仓库id")
    private Integer placeId;

    @ApiModelProperty(value = "订单来源对象集合")
    private List<OrderSourceSave> orderSourceSaveList;

    @ApiModelProperty(value = "销售区域排行对象集合")
    private List<AreaSalesSave> areaSalesSaveList;

    @ApiModelProperty(value = "商品销售量对象集合")
    private List<GoodsSalesSave> goodsSalesSaveList;

    @ApiModelProperty(value = "物流公司包裹对象集合")
    private List<LogisticsSave> logisticsSaveList;

    @ApiModelProperty(value = "区域商品销量排行对象集合")
    private List<GoodsAreaSalesSave> goodsAreaSalesSaveList;

    @ApiModelProperty(value = "设备设施对象集合")
    private List<DeviceSave> deviceSaveList;

    @ApiModelProperty(value = "业务类型对象集合")
    private List<BussTypeSave> bussTypeSaveList;

    @ApiModelProperty(value = "发货量历史明细对象集合")
    private List<DeliveringDetailSave> deliveringDetailSaves;


    @Data
    public
    static class OrderSourceSave{

        @ApiModelProperty(value = "来源渠道")
        private String sourceChannel;

        @ApiModelProperty(value = "销售额")
        private BigDecimal amout;

        @ApiModelProperty(value = "订单数量")
        private Long orderNum;

        @ApiModelProperty(value = "平台类型（其值为：零售、大宗）")
        private String type;
    }

    @Data
    public
    static class BussTypeSave{
        @ApiModelProperty(value = "业务类型")
        private String typeName;

        @ApiModelProperty(value = "业务说明")
        private String description;

        @ApiModelProperty(value = "备注")
        private String remarks;

        @ApiModelProperty(value = "占比")
        private Integer ratio;
    }
    @Data
    public
    static class GoodsStockSave{
        @ApiModelProperty(value = "商品名称")
        private String goodsName;

        @ApiModelProperty(value = "销量")
        private String goodsNum;

        @ApiModelProperty(value = "品类")
        private String productItem;
    }

    @Data
    public
    static class AreaSalesSave{
        @ApiModelProperty(value = "销售区域")
        private String salesArea;

        @ApiModelProperty(value = "销售金额")
        private BigDecimal amout;

    }
    @Data
    public
    static class DeviceSave{
        @ApiModelProperty(value = "设备名称")
        private String deviceName;

        @ApiModelProperty(value = "数量")
        private Integer deviceNum;

        @ApiModelProperty(value = "单位")
        private String deviceItem;

        @ApiModelProperty(value = "标准数量")
        private Integer standardNum;
    }
    @Data
    public
    static class GoodsSalesSave{
        @ApiModelProperty(value = "商品名称")
        private String goodsName;

        @ApiModelProperty(value = "销量")
        private String goodsNum;

        @ApiModelProperty(value = "品类")
        private String productItem;
    }
    @Data
    public
    static class LogisticsSave{
        @ApiModelProperty(value = "物流公司")
        private String logisticsName;

        @ApiModelProperty(value = "包裹数量")
        private Long packageNum;

        @ApiModelProperty(value = "价格（元）")
        private BigDecimal price;

        @ApiModelProperty(value = "重量（单位公斤）")
        private BigDecimal weight;
    }
    @Data
    public
    static class GoodsAreaSalesSave{
        @ApiModelProperty(value = "销售区域")
        private String salesArea;

        @ApiModelProperty(value = "销售金额")
        private BigDecimal amout;
    }


    @Data
    static public
    @ApiModel(description="发货量历史明细保存")
    class DeliveringDetailSave{

        @ApiModelProperty(value = "年月（yyyy-MM）")
        private String dateTime;

        @ApiModelProperty(value = "发货数量")
        private Integer deliveringNum;


    }
}
